// Decompiled by Jad v1.5.8e2. Copyright 2001 Pavel Kouznetsov.
// Jad home page: http://kpdus.tripod.com/jad.html
// Decompiler options: packimports(3) fieldsfirst ansi 
// Source File Name:   yt.java

package com.zelix;

import java.io.*;
import java.util.*;

// Referenced classes of package com.zelix:
//            pt, z0, fh, tb, 
//            dc, is, zs, sm, 
//            lt, kt, k5, lx, 
//            px, qy, zu, f6, 
//            h6, jb, nh

class yt extends pt
    implements sm
{

    private zs o;
    private static char j[];
    private static char n[];
    private static char p[];
    private static String z[];

    yt(kt kt1, int i, String s, jb jb, qy qy1)
        throws IOException, dc
    {
        super(kt1, i, s, jb, qy1);
        int k = jb.readUnsignedShort();
        is is1 = a(k);
        a(is1);
        qy1.b(o, this);
    }

    void a(int i, int k, Hashtable hashtable)
        throws tb
    {
        String s;
        f6 f6_1;
        Iterator iterator;
        int j2;
        j2 = kt.i;
        if(k == 1)
            return;
        s = o.b();
        f6_1 = a();
        if(f6_1 == null)
            return;
        iterator = f6_1.c();
        if(j2 == 0) goto _L2; else goto _L1
_L1:
        Object obj;
        Object obj1;
        ArrayList arraylist;
        k5 k5_1;
        obj = (h6)iterator.next();
        obj1 = (k5)((h6) (obj)).c();
        if(!((k5) (obj1)).f())
            break MISSING_BLOCK_LABEL_866;
        arraylist = new ArrayList();
        arraylist.add(obj1);
        k5_1 = ((k5) (obj1)).b();
        if(j2 == 0) goto _L4; else goto _L3
_L3:
        arraylist.add(k5_1);
        k5_1 = k5_1.b();
_L4:
        if(k5_1 != null) goto _L3; else goto _L5
_L5:
        StringBuffer stringbuffer;
        int l;
        stringbuffer = new StringBuffer();
        l = 0;
        if(j2 == 0) goto _L7; else goto _L6
_L6:
        if(l > 0)
            stringbuffer.append("$");
        stringbuffer.append(((k5)arraylist.get(l)).a());
        l++;
_L7:
        if(l < arraylist.size()) goto _L6; else goto _L8
_L8:
        String s3;
        String s5;
        String s6;
        String s7;
        boolean flag;
        StringTokenizer stringtokenizer;
        int i1;
label0:
        {
            s3 = stringbuffer.toString();
            String s4 = lt.h(s3);
            s5 = (String)px.a(s3, hashtable);
            s6 = lt.f(s5);
            s7 = lt.h(s5);
            if(i == 0 || i == 2 && s4.equals(s7))
            {
                flag = true;
                if(j2 == 0)
                    break label0;
            }
            flag = false;
        }
        if(s3.equals(s5) && flag)
            continue; /* Loop/switch isn't completed */
        stringtokenizer = new StringTokenizer(s7, z[2]);
        if(stringtokenizer.countTokens() == 1)
        {
            a(f6_1, ((k5) (obj1)), ((h6) (obj)), arraylist, iterator, s5);
            if(j2 == 0)
                continue; /* Loop/switch isn't completed */
        }
        if(stringtokenizer.countTokens() != arraylist.size())
            break MISSING_BLOCK_LABEL_458;
        if(!flag)
            break MISSING_BLOCK_LABEL_437;
        i1 = 0;
        if(j2 == 0) goto _L10; else goto _L9
_L9:
        String s9 = stringtokenizer.nextToken();
        if(i1 == 0)
            s9 = (s6.length() <= 0 ? "" : s6 + "/") + s9;
        ((k5)arraylist.get(i1)).a(s9);
        i1++;
_L10:
        if(stringtokenizer.hasMoreTokens()) goto _L9; else goto _L11
_L11:
        if(j2 == 0)
            continue; /* Loop/switch isn't completed */
        a(f6_1, ((k5) (obj1)), ((h6) (obj)), arraylist, iterator, s5);
        if(j2 == 0)
            continue; /* Loop/switch isn't completed */
        String s8;
        int j1;
        int k1;
        Iterator iterator1;
        if(!flag)
            break MISSING_BLOCK_LABEL_845;
        s8 = s7;
        j1 = stringtokenizer.countTokens() - arraylist.size();
        k1 = 0;
        iterator1 = arraylist.iterator();
        if(j2 == 0) goto _L13; else goto _L12
_L12:
        k5 k5_2;
        String s10;
        String s11;
label1:
        {
            k5_2 = (k5)iterator1.next();
            s10 = k5_2.a();
            if(k1 == 0)
            {
                s11 = lt.h(s10);
                if(j2 == 0)
                    break label1;
            }
            s11 = s10;
        }
        int i2 = zu.a(s11, '$') + zu.a(s11, '+');
        lx.b(s8.startsWith(s11), "'" + h().i() + z[0] + s3 + z[0] + s5 + z[0] + s8 + z[1] + s11 + "'");
        s8 = s8.substring(s11.length() + (arraylist.size() != 1 ? 1 : 0));
        iterator1.remove();
        if(k1 == 0)
        {
            String s13 = (s6.length() <= 0 ? "" : s6 + "/") + s11;
            if(!s13.equals(s10))
                k5_2.a(s13);
        }
        j1 -= i2;
        k1++;
_L13:
        if(iterator1.hasNext() && j1 > 0) goto _L12; else goto _L14
_L14:
        StringTokenizer stringtokenizer1;
        int l1;
        if(arraylist.size() <= 0)
            continue; /* Loop/switch isn't completed */
        stringtokenizer1 = new StringTokenizer(s8, z[2]);
        l1 = 0;
        if(j2 == 0) goto _L16; else goto _L15
_L15:
        String s12 = stringtokenizer1.nextToken();
        ((k5)arraylist.get(l1)).a(s12);
        l1++;
_L16:
        if(stringtokenizer1.hasMoreTokens()) goto _L15; else goto _L17
_L17:
        if(j2 == 0)
            continue; /* Loop/switch isn't completed */
        a(f6_1, ((k5) (obj1)), ((h6) (obj)), arraylist, iterator, s5);
        if(j2 == 0)
            continue; /* Loop/switch isn't completed */
        if(!((k5) (obj1)).e())
        {
            String s1 = ((k5) (obj1)).a();
            if(s1 != null)
            {
                String s2 = (String)px.a(s1, hashtable);
                if(!s1.equals(s2))
                    ((k5) (obj1)).a(s2);
            }
        }
_L2:
        if(iterator.hasNext()) goto _L1; else goto _L18
_L18:
        obj = new StringBuffer(s.length());
        obj1 = f6_1.d();
        if(j2 == 0) goto _L20; else goto _L19
_L19:
        ((StringBuffer) (obj)).append(((k5)((Enumeration) (obj1)).nextElement()).d());
_L20:
        if(!((Enumeration) (obj1)).hasMoreElements())
        {
            if(!s.equals(((StringBuffer) (obj)).toString()))
                o.a(((StringBuffer) (obj)).toString());
            return;
        }
        if(true) goto _L19; else goto _L21
_L21:
    }

    public void a(zs zs1, zs zs2)
    {
label0:
        {
            if(o == zs1)
            {
                o = zs2;
                if(kt.i == 0)
                    break label0;
            }
            super.a(zs1, zs2);
        }
    }

    f6 a()
        throws tb
    {
        String s;
        int i2;
        i2 = kt.i;
        s = o.b();
        Object obj = null;
        f6 f6_1;
        int i;
        int k;
        f6_1 = new f6(new k5("", null));
        i = zu.a(s, 0, j);
        if(i == -1)
            return null;
        k = 0;
        if(i2 == 0) goto _L2; else goto _L1
_L1:
        char c;
        int l;
        char c2;
        c = s.charAt(i);
        l = zu.a(s, i, p);
        if(l == -1)
            throw new tb(z[7] + getClass().getName() + z[4] + s + z[3] + i);
        char c1 = s.charAt(l);
        if(c1 == ':')
        {
            i = zu.a(s, l, n);
            if(i2 == 0)
                continue; /* Loop/switch isn't completed */
        }
        c2 = s.charAt(k);
        Object obj1 = null;
        if(c != 'T') goto _L4; else goto _L3
_L3:
        String s1;
        k5 k5_3;
        s1 = s.substring(k, l);
        k5_3 = new k5(s1, null);
        if(i2 == 0) goto _L5; else goto _L4
_L4:
        s1 = s.substring(k, i + 1);
        String s3 = s.substring(i + 1, l);
        k5_3 = new k5(s1, s3, c == '.');
_L5:
        int k1;
        int l1;
        int i1 = zu.a(s1, '<');
        int j1 = zu.a(s1, '>');
        k1 = j1 - i1;
        l1 = 0;
        if(i2 == 0) goto _L7; else goto _L6
_L6:
        f6_1.a();
        l1++;
_L7:
        if(l1 < k1) goto _L6; else goto _L8
_L8:
        if(!f6_1.b() && (k <= 0 || c2 != '<')) goto _L10; else goto _L9
_L9:
        f6_1.a(k5_3);
        if(i2 == 0) goto _L11; else goto _L10
_L10:
        f6_1.b(k5_3);
_L11:
        k = l;
        i = zu.a(s, k, n);
        if(i == -1)
        {
            String s2 = s.substring(k);
            f6_1.b(new k5(s2, null));
        }
_L2:
        if(i > -1) goto _L1; else goto _L12
_L12:
        break MISSING_BLOCK_LABEL_459;
        z0 z0_1;
        z0_1;
        throw new tb(z[5] + getClass().getName() + z[4] + s + z[6] + z0_1.getMessage() + "'");
        Iterator iterator = f6_1.c();
        if(i2 == 0) goto _L14; else goto _L13
_L13:
        h6 h6_1 = (h6)iterator.next();
        k5 k5_1 = null;
        for(Enumeration enumeration = h6_1.a(); enumeration.hasMoreElements();)
        {
            h6 h6_2 = (h6)enumeration.nextElement();
            k5 k5_2 = (k5)h6_2.c();
            k5_2.a(h6_2);
            if(k5_2.e())
                k5_1.a(k5_2);
            k5_1 = k5_2;
        }

_L14:
        if(!iterator.hasNext())
            return f6_1;
        if(true) goto _L13; else goto _L15
_L15:
    }

    void a(HashSet hashset)
        throws tb
    {
        f6 f6_1;
        int i;
        i = kt.i;
        String s = o.b();
        f6_1 = a();
        if(f6_1 == null) goto _L2; else goto _L1
_L1:
        Enumeration enumeration = f6_1.d();
        if(i == 0) goto _L4; else goto _L3
_L3:
        String s1;
        k5 k5_1;
        StringBuffer stringbuffer;
        k5 k5_2;
        s1 = null;
        k5_1 = (k5)enumeration.nextElement();
        if(!k5_1.f())
            break MISSING_BLOCK_LABEL_129;
        stringbuffer = new StringBuffer();
        stringbuffer.append(k5_1.a());
        k5_2 = k5_1.b();
        if(i == 0) goto _L6; else goto _L5
_L5:
        stringbuffer.append("$");
        stringbuffer.append(k5_2.a());
        k5_2 = k5_2.b();
_L6:
        if(k5_2 != null) goto _L5; else goto _L7
_L7:
        s1 = stringbuffer.toString();
        break MISSING_BLOCK_LABEL_144;
        if(!k5_1.e())
            s1 = k5_1.a();
        if(s1 != null)
        {
            mt mt = fh.a(s1);
            if(mt != null)
                hashset.add(mt);
        }
_L4:
        if(enumeration.hasMoreElements()) goto _L3; else goto _L2
_L2:
    }

    public void a(Hashtable hashtable)
    {
        super.a(hashtable);
        hashtable.put(o, this);
    }

    private void a(f6 f6_1, k5 k5_1, h6 h6_1, ArrayList arraylist, Iterator iterator, String s)
    {
        k5 k5_2;
        k5 k5_3;
        int i;
        int k;
        k = kt.i;
        k5_2 = (k5)arraylist.get(0);
        k5_3 = (k5)arraylist.get(arraylist.size() - 1);
        i = 0;
        if(k == 0) goto _L2; else goto _L1
_L1:
        k5 k5_4 = (k5)arraylist.get(i);
        iterator.remove();
        if(i < arraylist.size() - 2)
        {
            h6_1 = (h6)iterator.next();
            k5_1 = (k5)h6_1.c();
        }
        i++;
_L2:
        if(i >= arraylist.size() - 1)
        {
            k5_3.b(k5_2.c());
            k5_3.a(s);
            k5_3.a(false);
            return;
        }
        if(true) goto _L1; else goto _L3
_L3:
    }

    void a(is is1)
        throws dc
    {
        o = (zs)is1;
    }

    protected final void a(DataOutputStream dataoutputstream, Hashtable hashtable, nh nh)
        throws IOException, tb
    {
label0:
        {
            super.a(dataoutputstream, hashtable, nh);
            zs zs1 = (zs)hashtable.get(o);
            if(zs1 != null)
            {
                dataoutputstream.writeShort(zs1.j());
                if(kt.i == 0)
                    break label0;
            }
            dataoutputstream.writeShort(o.j());
        }
    }

    private static String z(char[] chs) {
        for (int i = 0; i < chs.length; i++) {
            byte key = 0;
            switch (i % 5) {
                case 0:
                    key = 0x4b;
                    break;
                case 1:
                    key = 4;
                    break;
                case 2:
                    key = 73;
                    break;
                case 3:
                    key = 90;
                    break;
                default:
                    key = 127;
                    break;
            }
            chs[i] ^= key;
        }
        return new String(chs).intern();
    }

    static
    {
        String as[];
        as = new String[8];
        as[0] = z("l$n".toCharArray());
        as[1] = z("l%t}".toCharArray());
        as[2] = z("o/".toCharArray());
        as[3] = z("l$sz".toCharArray());
        as[4] = z("k>i}".toCharArray());
        as[5] = z("\037v,?_.v;5\rkm'z".toCharArray());
        as[6] = z("l$szX".toCharArray());
        as[7] = z("\033e;)\032ka;(\0209$ 4_".toCharArray());
        z = as;
        j = (new char[] {
            'L', 'T'
        });
        n = (new char[] {
            'L', 'T', '.'
        });
        p = (new char[] {
            ';', '<', ':'
        });
    }
}
